package com.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.mapper.StudentMapper;
import com.pojo.Student;
import com.service.StudentService;

@Service
@Transactional
public class StudentServiceImpl implements StudentService{
	@Autowired
	StudentMapper studentMapper;

	@Override
	public List<Student> list() {
		// TODO Auto-generated method stub
		return studentMapper.list();
	}

	@Override
	public void add(Student s) {
		// TODO Auto-generated method stub
		studentMapper.add(s);
	}

	@Override
	public void update(Student s) {
		// TODO Auto-generated method stub
		studentMapper.update(s);
	}

	@Override
	public void delete(Student s) {
		// TODO Auto-generated method stub
		studentMapper.delete(s.getStuID());
	}
	
	
}
